package com.reggie.utils;

/**
 * ThreadLocal的工具类
 * 对于ThreadLocal空间的赋值和去取值
 * @program: reggie
 * @author:
 * @create: 2022-09-28 11:45
 **/
public class ThreadLocalUtil {
    public static ThreadLocal<Long> threadLocal=new ThreadLocal<>();

    public static void setId(Long id){
        threadLocal.set(id);
    }
    public static Long getId(){
        return threadLocal.get();
    }
}
